<div id="nav">
  <ul>
    <li><%= link_to("Home", "/", :class=>"button")  %></li>
    <% if is_admin(session[:user_id])%>  <li><%= link_to("All Posts", admin_path, :class=>"button")  %></li><%end%>
    <% if is_admin(session[:user_id])%>  <li><%= link_to("Category Controls", category_control_panel_path, :class=>"button")  %></li><%end%>
    <% if is_admin(session[:user_id])%>  <li><%= link_to("Access Rule Controls", rules_index_path, :class=>"button")  %></li><%end%>
    <li><%= link_to("Members", "/users/", :class=>"button")  %></li>
  </ul>
</div>

<div id="login_banner">
  <ul>
    <% if @current_user %>
	      Logged in as: <%=h @current_user.name %>
      <li><%= link_to(" Logout", session_path, {:method => :delete, :class=>"button"})  %></li>
    <% else %>
	      Not Logged In.
      <li><%= link_to 'Login', new_session_path, :class=>"button" %></li>
      <li><%= link_to 'Register', '/users/new', :class=>"button"  %></li>
    <%end%>
  </ul>
</div>